from selenium import webdriver
import os
opt = webdriver.FirefoxOptions()
ex = "../lib/conf/geckodriver.exe"
opt.profile = r'%s\AppData\Roaming\Mozilla\Firefox\Profiles\svafs5fu.default-release' % os.environ["USERPROFILE"]
driver = webdriver.Firefox(executable_path=ex,firefox_options=opt)

driver.implicitly_wait(10)
driver.get("http://gshx.greenyouxi.com/account/index.php/account/create")
ele = driver.find_element_by_xpath("//img[@id='captcha']")
ele.screenshot("../lib/verify/verify.png")

from common.verify import Verify
ver = Verify('wuqingfqng', '6e8ebd2e301f3d5331e1e230ff3f3ca5', '96001')
print(ver.PostPic(1902,im="../lib/verify/verify.png"))